/*

Author   : chaos

FileName : inh_ini.cpp

Date     : 14/08/17 10:21:56

*/
#include <iostream>
#include <cstring>
using namespace std;

class library_object
{
    protected:
        char name[30];
        long index;

    public:
        library_object()
        {
            cout << "library_object's default constructor" << endl;
        }

        library_object(const char * i_name)
        {
            cout << "library_object's 1-parament constructor " << endl;
            strcpy(name,i_name);
            index = 1;
        }
};

class Book:public library_object
{
    private:
        bool on_shelf;

    public:
        Book()
        {
            cout << "Book's default constuctor " << endl;
        }

        Book(const char * name):library_object(name){
            cout << "Boos's 1-parameter constructor " << endl;
            on_shelf = true;
        }
};

int main(int argc ,char *argv[])
{
    Book A_Book("The C++ Bible");
    Book B_Book;

    return 0;
}
